import layout from '../layout/layout.vue'

function load(component) {
  return () => import(`../pages/${component}.vue`)
}

export default [
  {
    path: '/login',
    component: load('login')
  },
  {
    path: '/',
    component: layout,
    children: [
      {
        path: '',
        component: load('home')
      }
    ]
  },
  {
    path: '*',
    component: load('404')
  }
]
